extends ../components/base
block title
    title 角色新建
block common_header
    include ../components/header
    +commonheader(0)
block style
    link(rel='stylesheet', href=__CSS_PATH__ + '/news.css')
    link(rel="stylesheet", href=__PLUGINS_PATH__ + "/ztree/zTreeStyle.css")
    style.
        #main-wrapper {
            margin-top: 10px;
        }
block aside_content
    include ../components/mixin
    -var routerObj = [{link:'/',text:'应用',icon:'icon-app'},{link:'/message',text:'消息',icon:'icon-message2'},{link:'/setting/user_manage',text:'平台管理',icon:'icon-setting'}]
    +asideNav(routerObj,2)
block main_content
    include ../components/mixin
    -var menuObj = [{link:'/setting/organization_manage',text:'平台自身管理'},{link:'/setting/contact_manage',text:'对接系统管理'},{link:'/setting/app_manage',text:'第三方应用系统管理'}]
    +menuLink(menuObj,0)
    -var navObj = [{link:'/setting/organization_manage',text:'组织机构管理'},{link:'/setting/user_manage',text:'用户管理'},{link:'#',text:'角色权限管理'},{link:'/setting/region_manage',text:'行政区划分'},{link:'/setting/log_manage',text:'日志管理'}]
    +menuNav(navObj,2)
    #inner-wrapper
        .user-permission
            .user-wrapper
                .user-handle
                    button#createRole.btn.btn-warning.btn-lg(onclick="window.location.href='/setting/role_edit'") 新建
                    button#editRole.btn.btn-warning.btn-lg 编辑
                    input#chooseRole(type='hidden' value="")
                ul.user-list
                    if(rolesList.length)
                        each role in rolesList
                            li.structure-node(data-role-id=role.id data-name=role.name data-users=role.users data-type=role.roleType) #{role.name}
            .manage-handle(style="position: absolute;margin-left: 200px;margin-top: 10px;")
                button#permissionSave.btn.btn-sm.btn-default 保存
                button.btn.btn-sm.btn-disable(style="margin-left:20px;") 取消
            .permission-handle
                input#deptIds(type='hidden' value="" name='deptIds')
                ul#tree.ztree(data-node=modulesList)
include ../components/checkTree
    +treeShow()


